home *** CD-ROM | disk | FTP | other *** search
/ MacAddict 108 / MacAddict108.iso / Software / Internet & Communication / Wirecast 2.0.dmg / Apple Scripts / NextShot.applescript next >
Encoding:
Text File  |  2005-05-25  |  699 b   |  23 lines

  1. (* This is an example of doing NextShot on a particular layer *)
  2.  
  3. tell application "Wirecast"
  4.     
  5.     set myDoc to last document
  6.     set normal_layer to the layer named "normal" of myDoc
  7.     set normal_shots to every shot of normal_layer
  8.     set normal_active to the active shot of normal_layer
  9.     
  10.     set myIndex to 1
  11.     repeat with aShot in normal_shots
  12.         if the id of aShot is the id of normal_active then
  13.             if the id of aShot is the id of the last shot of normal_layer then
  14.                 set the active shot of normal_layer to the first item of normal_shots
  15.             else
  16.                 set the active shot of normal_layer to item (myIndex + 1) of normal_shots
  17.             end if
  18.         end if
  19.         set myIndex to myIndex + 1 -- bump 
  20.     end repeat
  21.     
  22. end tell
  23.